package com.microservices.yucloud.gateway.controller;

import com.microservices.yucloud.gateway.service.TestService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author zy
 * @date 2019-08-06 20:01
 **/
@Slf4j
@RestController
public class ApiController {

    @Autowired
    private TestService testService;

    @GetMapping("/test1")
    public String test1(@RequestParam String key) {
        log.info("API gateway test1:{}",key);
        return testService.test1(key);
    }
}
